package org.mall.modules.promotion.service;

import org.mall.common.aspect.annotation.InEnum;
import org.mall.common.constant.CommonStatusEnum;
import org.mall.common.exception.ServiceException;
import org.mall.modules.pojo.promotion.bo.ProductRecommendBO;
import org.mall.modules.pojo.promotion.bo.ProductRecommendPageBO;
import org.mall.modules.pojo.promotion.dto.ProductRecommendAddDTO;
import org.mall.modules.pojo.promotion.dto.ProductRecommendPageDTO;
import org.mall.modules.pojo.promotion.dto.ProductRecommendUpdateDTO;

import java.util.List;

public interface ProductRecommendService {

    List<ProductRecommendBO> getProductRecommendList(Integer type, Integer status);

    ProductRecommendPageBO getProductRecommendPage(ProductRecommendPageDTO productRecommendPageDTO);

    ProductRecommendBO addProductRecommend(String adminId, ProductRecommendAddDTO productRecommendAddDTO) throws ServiceException;

    Boolean updateProductRecommend(String adminId, ProductRecommendUpdateDTO productRecommendUpdateDTO) throws ServiceException;

    Boolean updateProductRecommendStatus(String adminId, Integer productRecommendId,
                                         @InEnum(value = CommonStatusEnum.class, message = "修改状态必须是 {value}") Integer status) throws ServiceException;

    Boolean deleteProductRecommend(String adminId, Integer productRecommendId);

    Boolean deleteBatchProductRecommend(String userIdByToken, String ids);

    ProductRecommendBO getProductBySpuId(Long id);

    List<ProductRecommendBO> getProductSortsofSpuid(List<Long> collect);
}
